Graphs & Topological Sort
Topological sort dominates Snowflake's graph reports more than any other single pattern, so if you budget your graph prep unevenly, spend it here. A topological sort answers one question. Given a pile of steps where some must finish before others can start, what order lets you run them? And is that even possible, or did somebody wire a cycle into the dependencies? The prerequisite-ordering problems and their weighted, level-counting variants are the recurring shapes, and they sit at the top of what candidates report from these rounds.
The reason it recurs is not subtle for a company that schedules dependent work for a living. A data platform is full of steps that wait on other steps. A task fires only after the task it depends on lands. A join cannot run until both its inputs are materialized, a refresh of a derived table waits on the tables it reads. Every one of those is a directed acyclic graph, and ordering a DAG so each node comes after everything it depends on is exactly topological sort. The interviewer reaches for the course-prerequisite phrasing because it is the cleanest way to ask the question the team answers all day.
SnowflakePremium lesson · Coding round
The 2 Snowflake problems are below.
- A Premium questionCoding · Hard · Signature problem
- A Premium questionCoding · Medium · Signature problem
Each with hints, the follow-up and a tested solution.
Get the Snowflake questions$49 a year · all 100 companies · cancel anytime
From 111 Snowflake reports, forum threads behind logins and write-ups in Chinese.
Snowflake interview guideKnow what Snowflake asks before you walk in.
10 coding · 5 system design · 18 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.